Skip to content

Add personal agent self-service to the client SDKs - #183

Open
sajitha-tj wants to merge 1 commit into
thunder-id:mainfrom
sajitha-tj:personal-agents-self-service
Open

sajitha-tj wants to merge 1 commit into
thunder-id:mainfrom
sajitha-tj:personal-agents-self-service

Conversation

@sajitha-tj

@sajitha-tj sajitha-tj commented Nov 18, 2026 •

Copy link
Copy Markdown

Purpose

Lets a signed-in user manage the personal assistant agents they own from a React or Vue app, through the owner self-service APIs under /users/me/agents. A user can list their agents, open one, edit it, delete it, suspend it or all of them at once, and lift their own suspension. An agent the organization suspended shows as such, and the user cannot lift that suspension.

The admin agent views also show personal agents: a "Personal" chip in AgentList, and "Kind" and "Suspended by" rows in AgentDetails. The admin actions on a suspended agent now depend on who placed the suspension. The organization can lift only its own suspension, so for an agent that only its owner suspended, the admin view offers Suspend instead of Unsuspend.

Approach

The issue proposed one <PersonalAgents/> component. This PR ships two, PersonalAgentList and PersonalAgentDetails, so an app can lay out the list and the selected agent the way its account portal needs. Each comes with an unstyled Base variant that takes a children render function.

@thunderid/javascript

  • API functions getMeAgents, getMeAgent, updateMeAgent, deleteMeAgent, suspendMeAgent, unsuspendMeAgent and suspendAllMeAgents, and the usersMeAgents endpoint key.
  • PERSONAL_AGENT_KIND, PERSONAL_AGENT_GRANT_TYPES and PERSONAL_AGENT_GRANT_TYPE_LABEL_KEYS, plus the kind and status.details.appliedBy models.
  • getMeAgentSuspensionAction, the shared form helpers (toPersonalAgentFormValues, toUpdateMeAgentRequest, isPersonalAgentFormValid), and the translations in every locale.
  • getAccountLifecycleActions takes who holds a suspension into account. If no party is reported, the suspension is treated as the organization's, so servers that don't report one behave as before.

@thunderid/react and @thunderid/vue

  • PersonalAgentList, PersonalAgentDetails and their Base variants. They call /users/me/agents with the SDK's own authenticated transport, not the management http.fetcher.
  • useResourceQuery and useResourceMutation are now exported, so SDKs built on React and Vue can load data the same way.
  • The admin agent views changes described above.

Playgrounds

  • React and Vue have sample and live stories for both components. The React playground also has MUI custom-render stories and a "Personal agents" capability check.

Screenshots

PersonalAgentList and PersonalAgentDetails with sample agents in the React playground:

PersonalAgentList PersonalAgentDetails

Related Issues

Related PRs

  • N/A

Checklist

  • Followed the contribution guidelines.
  • Manual test round performed and verified.
  • Documentation provided. (Add links if there are any)
  • Tests provided. (Add links if there are any)
    • Unit Tests
    • Integration Tests
  • Breaking changes. (Fill if applicable)
    • Breaking changes section filled.
    • breaking change label added.
  • Cross-SDK parity. Exactly one of parity/prs-raised or parity/prs-not-needed added.
    • If parity/prs-raised, the port links are posted as a reply on the parity check's comment.

Security checks

  • Followed secure coding standards.
  • Confirmed that this PR doesn't commit any keys, passwords, tokens, usernames, or other secrets.

@coderabbitai

coderabbitai Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@github-actions

Copy link
Copy Markdown

🔀 Cross-SDK feature parity

Does this change need to ship in the other ThunderID SDKs too? This check stays red until one of these labels answers that:

Label What it asserts
parity/prs-raised The ports exist in every other SDK this change reaches, or are recorded as not applying there.
parity/prs-not-needed Nothing to port: a fix, refactor, docs, CI, dependency bump, release, or a change specific to this platform.

Ports (DO NOT EDIT)

  • thunder-id/ios-sdks, iOS
  • thunder-id/android-sdks, Android
  • thunder-id/flutter-sdks, Flutter

No sibling SDKs accounted for on this thread yet.

Important

Reply to this comment with this block, filled in. The boxes above tick
themselves when you post it.

- thunder-id/ios-sdks: <paste the port link here>
- thunder-id/android-sdks: <paste the port link here>
- thunder-id/flutter-sdks: <paste the port link here>

A link can be a pull request or a tracked issue, written in full or as thunder-id/ios-sdks#123.
Where the change does not reach an SDK, replace the placeholder with N/A and a short
reason, as in - thunder-id/ios-sdks: N/A, the capability has no equivalent there.

The contract is in the SDK development specification.

Let a signed-in user list, view, edit, delete and suspend their own
personal agents through /users/me/agents in the React and Vue SDKs,
and show the personal kind and who applied a suspension in the admin
agent views.

Refs thunder-id/thunderid#4468

Signed-off-by: sajitha-tj <sajitha.jayawickrama@gmail.com>
@sajitha-tj
sajitha-tj force-pushed the personal-agents-self-service branch from ecb1248 to 47d00ab Compare November 18, 2026 04:51
@sajitha-tj sajitha-tj changed the title Add personal agent self-service to the JavaScript SDKs Add personal agent self-service to the client SDKs Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant